<!DOCTYPE html>
<html lang="en">
  <head>
    <meta charset="UTF-8" />
    <meta name="viewport" content="width=device-width, initial-scale=1.0" />
    <title>Document</title>
  </head>
  <body>
    <script>
      function min(a, b, c) {
        switch (true) {
          case a < b && a < c:
            return a;
          case b < a && b < c:
            return b;
          case c < a && c < b:
            return c;
        }
      }
      console.log(min(1, -2, 3));
    </script>
  </body>
</html>
